package cn.jdx.shiro;

import org.springframework.util.DigestUtils;

import java.nio.charset.StandardCharsets;

public class MD5Utils {

    private static final String salt = "";
    public static String getMD5(String string){
        String val = string;
        return DigestUtils.md5DigestAsHex(val.getBytes(StandardCharsets.UTF_8));
    }
    public static void main(String[] args) {
        System.out.println(getMD5("root"));
    }
}
